import request from "@/utils/request";
export default {
// 查询
inquire(name){
    return request({
      url: `/area/inquire?name=${name}`,
      method:"get"
    });
},
  // 获取区域列表
  getareasList() {
    return request({
      url: "/area/list",
      method: "get",
    });
  },
  // 添加区域
  areaadd(name, phone, auth_name, administer) {
    return request({
      url: "/area/add",
      method: "post",
      data: {
        name,
        phone,
        auth_name,
        administer,
      },
    });
  },
  // 更新区域
  updatearea(area) {
    return request({
      url: "/area/update",
      method: "post",
      data: area,
    });
  },
  // 删除区域
  areaDelete(row) {
    return request({
      url: "/area/delete",
      method: "delete",
      data: row,
    });
  },
  // 分页获取区域
  areaList(page, size) {
    return request({
      url: "/area/condition",
      method: "post",
      data: {
        page,
        size,
      },
    });
  },
};